<template>
    <div>
        <!-- <input type="checkbox" @click="show=!show" :checked=show> -->
        <input type="radio" v-model="checked" value="1">男性
        <input type="radio" v-model="checked" value="2">女性
        <!-- <h3>{{ show? '选中' : '未选中' }}</h3> -->
        <button @click="submit">提交</button>
    </div>
</template>
<script>
export default {
    name:'text-jiu',
    data(){
        return{
            checked:1,
            gender:this.checked,
        }
    },
    methods:{
        submit(){
            console.log(`gender:'${this.checked}'`);
        }
    }
}
</script>